package com.rocky.study.myenum;

// Enum singleton - the preferred approach
public enum EnumType {
    INSTANCE;

    public void leaveTheBuilding() {
        System.out.println("who a baby,I'm outta here!");
    }

    // This code would normally appear outside the class!
    public static void main(String[] args) {
        EnumType enumType = EnumType.INSTANCE;
        enumType.leaveTheBuilding();
    }
}
